function person(name,age){
    this.name=name;
    this.age=age;
    tjis.greet=function(){
        return "hello my name is"+this.name+"and i am"+tjis.age+"year old.";
    }
}
var person1=new person("张三",30)
console.log(person1.greet());